<html>
<script>

if (window.testRunner) {
    testRunner.waitUntilDone();
    testRunner.dumpBackForwardList();
    testRunner.dumpAsText();
}

function runTest()
{
    var iframe = document.createElement("iframe");
    iframe.setAttribute("name", "testFrame");
    document.body.appendChild(iframe);

    var otherDocument = iframe.contentWindow.document;

    var form = otherDocument.createElement("form");
    form.setAttribute("action", "resources/notify-done.html");
    form.setAttribute("name", "TestForm");
    form.setAttribute("target", "testFrame");
    form.setAttribute("method", "post");
    var button = otherDocument.createElement("input");
    button.setAttribute("type", "submit");
    form.appendChild(button);
    otherDocument.body.appendChild(form);

    form.submit();
}

</script>
<body onload="setTimeout('runTest();', 0);">
This test sees if dynamically creating an iframe, dynamically adding form elements to it, and dynamically submitting the form result in an extra back/forward entry.  It is important that these steps run after the initial load is complete, hence the setTimeout() for running the test.<br>
</body>
</html>
